<template>
	<base-breadcrumb>
				<a-card>
				<TitleName title="分包技术标评审"></TitleName>
				<a-form>
					<a-row :gutter="24">
						<a-col :md="8" :sm="8">
							<a-form-item label="所属分公司" 
							:labelCol="{ lg: { span: 6 }, sm: { span: 6 } }" 
							:wrapperCol="{ lg: { span: 16 }, sm: { span: 16 } }">
								<a-select placeholder="请选择">
									<a-select-option value="0">是</a-select-option>
									<a-select-option value="1">否</a-select-option>
								</a-select>
							</a-form-item>
						</a-col>
						<a-col :md="8" :sm="8">
							<a-form-item label="所属项目" 
							:labelCol="{ lg: { span: 5 }, sm: { span: 5 } }" 
							:wrapperCol="{ lg: { span: 17 }, sm: { span: 17 } }">
								<a-select placeholder="请选择">
									<a-select-option value="0">是</a-select-option>
									<a-select-option value="1">否</a-select-option>
								</a-select>
							</a-form-item>
						</a-col>
						<a-col :md="8" :sm="8">
							<span class="table-page-search-submitButtons">
								<a-button type="primary" @click="addSearch">搜索</a-button>
								<a-button style="margin-left: 8px" @click="addEmpty">重置</a-button>
								<a @click="toggleAdvanced" style="margin-left: 8px">
									{{ advanced ? '收起' : '展开' }}
									<a-icon :type="advanced ? 'up' : 'down'" />
								</a>
							</span>
						</a-col>
					</a-row>
					<div v-if="advanced">
						<a-row :gutter="24">
							<a-col :md="8" :sm="8">
								<a-form-item label="方案名称" 
								:labelCol="{ lg: { span: 5 }, sm: { span: 5 } }" 
								:wrapperCol="{ lg: { span: 17 }, sm: { span: 17 } }">
									<BaseInput placeholder=""  />
								</a-form-item>
							</a-col>
						
							<a-col :md="8" :sm="6">
								<a-form-item label="专业单位名称" 
								:labelCol="{ lg: { span: 7 }, sm: { span: 7 } }" 
								:wrapperCol="{ lg: { span: 15 }, sm: { span: 15 } }">
									<BaseInput  />
								</a-form-item>
							</a-col>
							<a-col :md="8" :sm="8">
								<a-form-item label="讲解人" 
								:labelCol="{ lg: { span: 5 }, sm: { span: 5 } }" 
								:wrapperCol="{ lg: { span: 17 }, sm: { span: 17 } }">
								<BaseInput  />
								</a-form-item>
							</a-col>
							<a-col :md="8" :sm="8">
								<a-form-item label="审核状态" 
								:labelCol="{ lg: { span: 5 }, sm: { span: 5 } }" 
								:wrapperCol="{ lg: { span: 17 }, sm: { span: 17 } }">
									<a-select placeholder="请选择">
										<a-select-option value="0">是</a-select-option>
										<a-select-option value="1">否</a-select-option>
									</a-select>
								</a-form-item>
							</a-col>
							<a-col :md="8" :sm="8">
								<a-form-item label="填报人" 
								:labelCol="{ lg: { span: 5 }, sm: { span: 5 } }" 
								:wrapperCol="{ lg: { span: 18 }, sm: { span: 17 } }">
									<BaseInput  />
								</a-form-item>
							</a-col>
							<a-col :md="8" :sm="8">
								<a-form-item label="填报时间" 
								:labelCol="{ lg: { span: 5 }, sm: { span: 5 } }" 
								:wrapperCol="{ lg: { span: 18 }, sm: { span: 17 } }">
									<BaseInput  />
								</a-form-item>
							</a-col>
						</a-row>
					</div>
				</a-form>
				</a-card>
			</div>
		<a-card>
			<div class="table-operator">
				<a-button type="primary" icon="plus" @click="handleAdd">新增上报</a-button>
				<p>专业分包方案数 30 ，已评讲方案数 18，专业分包方案评讲率为：60%</p>
			</div>
			<a-table 
			:data-source="dataSource" 
			:columns="columns" 
			bordered 
			:pagination="false"
			>
				<span slot="description" slot-scope="text">
					<ellipsis :length="8" tooltip>{{ text }}</ellipsis>
				</span>
				<!-- 操作 -->
				<span slot="operation" slot-scope="text, record">
					<template>
						<a @click="detailed(record)">查看</a>
						<a-divider type="vertical" />
						<a @click="addEdit(record)">编辑</a>
						<a-divider type="vertical" />
						<a @click="discard(record)">删除</a>
					</template>
				</span>
			</a-table>
		</a-card>
	</base-breadcrumb>
</template>

<script>
	import TitleName from '@/components/TitleName/index.vue'
	const columns = [
		{
			title: '名称',
			dataIndex: 'projectName'
		},
		{
			title: '所属分公司',
			dataIndex: 'projectTitle'
		},
		{
			title: '所属项目',
			dataIndex: 'optimization'
		},
		{
			title: '方案名称',
			dataIndex: 'branchCompanyRank'
		},
		{
			title: '专业单位名称',
			dataIndex: 'branchCompany'
		},
		{
			title: '讲解人',
			dataIndex: 'fillingInTime'
		},
		{
			title: '上传人',
			dataIndex: 'fillingInTime1'
		},
		{
			title: '状态',
			dataIndex: 'fillingInTime2'
		},
		{
			title: '上传时间',
			dataIndex: 'fillingInTime3'
		},
		{
			title: '操作',
			dataIndex: 'operation',
			width: '170px',
			scopedSlots: { customRender: 'operation' }
		}
	];
	export default{
		components:{
			TitleName
		},
		data(){
			this.columns = columns
			return{
				advanced: false,
				dataSource: []
			}
		},
		methods:{
			addEmpty() {},
			addSearch() {},
			// 收起展开
			toggleAdvanced() {
				this.advanced = !this.advanced;
			},
			//新增
			handleAdd(){
				this.$router.push('/technical/branchPackage/speakReview/newIncrease')
			}
		}
	}
</script>

<style>
</style>

